converting pandas string categories to numeric categories